package com.xiaoyun.ui;

import javax.swing.JPanel;
import java.awt.GridBagLayout;
import java.awt.GridBagConstraints;
import javax.swing.JTabbedPane;
import java.awt.Insets;
import javax.swing.JLabel;
import javax.swing.JButton;
import javax.swing.JTextField;
import javax.swing.JScrollPane;
import javax.swing.JComboBox;

public class CmmodityMsgPanel extends JPanel {
	private JTextField textField;
	private JTextField tfID;
	private JTextField tfName;
	private JTextField tfPassword;
	private JTextField tfTel;
	private JTextField textField_1;
	private JTextField textField_2;
	private JTextField textField_3;
	private JTextField textField_4;
	private JTextField textField_5;
	private JTextField textField_6;

	/**
	 * Create the panel.
	 */
	public CmmodityMsgPanel() {
		GridBagLayout gridBagLayout = new GridBagLayout();
		gridBagLayout.columnWidths = new int[]{722, 0};
		gridBagLayout.rowHeights = new int[]{33, 31, 35, 158, 33, 0};
		gridBagLayout.columnWeights = new double[]{1.0, Double.MIN_VALUE};
		gridBagLayout.rowWeights = new double[]{0.0, 0.0, 0.0, 1.0, 0.0, Double.MIN_VALUE};
		setLayout(gridBagLayout);
		
		JPanel panel = new JPanel();
		GridBagConstraints gbc_panel = new GridBagConstraints();
		gbc_panel.fill = GridBagConstraints.BOTH;
		gbc_panel.insets = new Insets(0, 0, 5, 0);
		gbc_panel.gridx = 0;
		gbc_panel.gridy = 0;
		add(panel, gbc_panel);
		
		JButton btnAdd = new JButton("添加商品");
		panel.add(btnAdd);
		
		JButton btnDelete = new JButton("删除商品");
		panel.add(btnDelete);
		
		JButton btnFix = new JButton("编辑商品");
		panel.add(btnFix);
		
		textField = new JTextField();
		panel.add(textField);
		textField.setColumns(10);
		
		JButton btnSearch = new JButton("搜索");
		panel.add(btnSearch);
		
		JPanel panel_1 = new JPanel();
		GridBagConstraints gbc_panel_1 = new GridBagConstraints();
		gbc_panel_1.fill = GridBagConstraints.BOTH;
		gbc_panel_1.insets = new Insets(0, 0, 5, 0);
		gbc_panel_1.gridx = 0;
		gbc_panel_1.gridy = 1;
		add(panel_1, gbc_panel_1);
		
		JLabel label = new JLabel("编号");
		panel_1.add(label);
		
		tfID = new JTextField();
		panel_1.add(tfID);
		tfID.setColumns(10);
		
		JLabel lblNewLabel = new JLabel("条形码");
		panel_1.add(lblNewLabel);
		
		tfName = new JTextField();
		panel_1.add(tfName);
		tfName.setColumns(10);
		
		JLabel label_3 = new JLabel("名称");
		panel_1.add(label_3);
		
		textField_1 = new JTextField();
		panel_1.add(textField_1);
		textField_1.setColumns(10);
		
		JLabel label_1 = new JLabel("单位");
		panel_1.add(label_1);
		
		tfPassword = new JTextField();
		panel_1.add(tfPassword);
		tfPassword.setColumns(10);
		
		JLabel label_2 = new JLabel("类别");
		panel_1.add(label_2);
		
		textField_2 = new JTextField();
		textField_2.setText("");
		panel_1.add(textField_2);
		textField_2.setColumns(10);
		
		JLabel label_4 = new JLabel("数量");
		panel_1.add(label_4);
		
		tfTel = new JTextField();
		panel_1.add(tfTel);
		tfTel.setColumns(10);
		
		JPanel panel_3 = new JPanel();
		GridBagConstraints gbc_panel_3 = new GridBagConstraints();
		gbc_panel_3.insets = new Insets(0, 0, 5, 0);
		gbc_panel_3.fill = GridBagConstraints.BOTH;
		gbc_panel_3.gridx = 0;
		gbc_panel_3.gridy = 2;
		add(panel_3, gbc_panel_3);
		
		JLabel label_5 = new JLabel("供应商");
		panel_3.add(label_5);
		
		textField_3 = new JTextField();
		panel_3.add(textField_3);
		textField_3.setColumns(10);
		
		JLabel lblNewLabel_1 = new JLabel("进价");
		panel_3.add(lblNewLabel_1);
		
		textField_4 = new JTextField();
		textField_4.setText("");
		panel_3.add(textField_4);
		textField_4.setColumns(10);
		
		JLabel lblNewLabel_2 = new JLabel("售价");
		panel_3.add(lblNewLabel_2);
		
		textField_5 = new JTextField();
		textField_5.setText("");
		panel_3.add(textField_5);
		textField_5.setColumns(10);
		
		JLabel label_6 = new JLabel("折扣价");
		panel_3.add(label_6);
		
		textField_6 = new JTextField();
		panel_3.add(textField_6);
		textField_6.setColumns(10);
		
		JScrollPane scrollPane = new JScrollPane();
		GridBagConstraints gbc_scrollPane = new GridBagConstraints();
		gbc_scrollPane.insets = new Insets(0, 0, 5, 0);
		gbc_scrollPane.fill = GridBagConstraints.BOTH;
		gbc_scrollPane.gridx = 0;
		gbc_scrollPane.gridy = 3;
		add(scrollPane, gbc_scrollPane);
		
		JPanel panel_2 = new JPanel();
		GridBagConstraints gbc_panel_2 = new GridBagConstraints();
		gbc_panel_2.fill = GridBagConstraints.BOTH;
		gbc_panel_2.gridx = 0;
		gbc_panel_2.gridy = 4;
		add(panel_2, gbc_panel_2);
		
		JButton btnBefore = new JButton("上一页");
		panel_2.add(btnBefore);
		
		JButton btnNext = new JButton("下一页");
		panel_2.add(btnNext);
		
		JComboBox cbPage = new JComboBox();
		panel_2.add(cbPage);
		
		JButton btnJump = new JButton("跳转");
		panel_2.add(btnJump);
		
		JLabel labelNow = new JLabel("第几页");
		panel_2.add(labelNow);
		
		JLabel labelAll = new JLabel("一共几页");
		panel_2.add(labelAll);

	}

}
